<div class="col-sm-12 search-collapse">
    <div class="layui-card-body">
        <div class="layui-collapse like-layui-collapse" lay-accordion=""
             style="border:1px dashed #c4c4c4">
            <div class="layui-colla-item">
                <h2 class="layui-colla-title like-layui-colla-title" style="background-color: #fff">操作提示<i
                            class="layui-icon layui-colla-icon"></i></h2>
                <div class="layui-colla-content layui-show">
                    <div>
                        可提现金额：<span style="font-size: xx-large;color: red"><?=$can_brokerage?></span>
                        <?php if ($can_brokerage>0):?>
                            <button type="button" style="margin-left: 10px;" class="btn btn-success with">提现</button>
                        <?php else:?>
                            <button type="button" style="margin-left: 10px;" class="btn btn-success disabled">提现</button>
                        <?php endif;?>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <form id="role-form">
        <input type="hidden" name="fund_type" value="<?=$input['fund_type']??''?>">
        <div class="select-list">
            <ul>
                <li class="select-time">
                    <label>申请时间： </label>
                    <?= \common\widgets\FormInput::widget(['name'=>'input','extend'=>['name'=>'between[create_time][start]','id'=>'startTime','place'=>'开始时间']])?>
                    <span>-</span>
                    <?= \common\widgets\FormInput::widget(['name'=>'input','extend'=>['name'=>'between[create_time][end]','id'=>'endTime','place'=>'结束时间']])?>
                </li>
                <li><?= \common\widgets\FormInput::widget(['name'=>'select|状态','extend'=>['name'=>'where[review_status]','value'=>'','place'=>'所有','data'=>$review_status]])?></li>
                <li>
                    <?= $this->render('/iframe',['name'=>'searchbtn|搜索'])?>
                    <?= $this->render('/iframe',['name'=>'resetbtn|重置'])?>
                </li>
            </ul>
        </div>
    </form>
</div>
<div class="col-sm-12 select-table table-striped">
    <table id="bootstrap-table"></table>
</div>

<?php $this->beginBlock('script'); ?>
<script>
    $(function () {
        bootUrl.url = "<?=\yii\helpers\Url::toRoute('my-list')?>"
        var options = {
            modalName: "提现记录",
            sortName:'create_time',
            sortOrder: "desc",
            type:0,
            columns: [
                {field: 'user_html', title: '打款微信'},
                {field: 'amount', title: '提现金额'},
                {field: 'fee', title: '手续费'},
                {field: 'payment_amount', title: '打款金额'},
                {field: 'way_title', title: '提现方式'},
                {field: 'review_status_title', title: '审核状态'},
                {field: 'review_time', title: '审核时间'},
                {field: 'review_remarks', title: '审核备注'},
                {field: 'create_time', title: '申请时间'},
            ]
        };
        $.table.init(options);
    });
    function detail_mine(id) {
        var url = "<?=\yii\helpers\Url::toRoute('water')?>";
        url=urlcreate(url,'userid=' + id);
        $.operate.detail("",null,null, url);
    }
    $('.with').click(function () {
        var url = "<?=\yii\helpers\Url::toRoute('apply')?>";
        $.modal.open("提现", url);
    })
</script>
<?php $this->endBlock(); ?>

